package CarRent;

import java.util.Scanner;
import CarRent.CarManager;

public class CarMgr {
    String name;//存储车牌信息
    boolean state;//存储借出状态
    int date;//存储接触天数
    int count;//存储借出次数
    static String menu[]={"1：新增车辆",
            "2：查看车辆",
            "3：删除淘汰车",
            "4：借出车辆",
            "5：车辆归还",
            "6：退出系统"};
    public static void main(String[] args) {
        CarManager cm = new CarManager();
        for (int i = 0 ; i<menu.length;i++){
            System.out.println(menu[i]);
        }
        Scanner scanner = new Scanner(System.in);
        int a;
        do {
           a = scanner.nextInt();
            switch (a) {
                case 1:
                    System.out.println("请输入车牌:");
                    String number1 =scanner.next();
                    System.out.println("请输入日租金（元）:");
                    int money = scanner.nextInt();
                    System.out.println(cm.addCar(number1,money));
                case 2:
                    System.out.println(cm.serCar());
                case 3:
                    System.out.println("请输入车牌:");
                    String number2 =scanner.next();
                    System.out.println(cm.delCar(number2));
                case 4:
                    System.out.println("请输入车牌:");
                    String number3 =scanner.next();
                    System.out.println(cm.catCar(number3));
                case 5:
                    System.out.println("请输入车牌:");
                    String number4 =scanner.next();
                    System.out.println(cm.givCar(number4));
                case 6:
                    break;
                default:
                    System.out.println("输入错误！");
            }
        }while (a==6);

    }
}
